<template>
    <div class="massifBox">
        <div class="massifPage" :style="{width:leftWidth}">
          <slot name="left"/>
        </div>
        <div class="mapbox">
          <slot/>
        </div>
    </div>
  </template>
  
  <script setup>
  // 这里的name是为了做页面缓存，其值要跟路由里面的name值一样
  
  import { nextTick, ref, watch, onActivated,reactive,onMounted} from 'vue'
  import {getCouseList} from '@/api/user'

  import { useUserStore } from '@/pinia/modules/user'

  import {message} from '@/utils/element'
  
  const userStore = useUserStore()

  const props = defineProps({
    leftWidth:''
  })

  onMounted(()=>{
    //initMap()
  })

  
  </script>
  
  <style lang="scss" scoped>
    .massifBox{
        display: flex;
        width: 100%;
        box-sizing: border-box;
        overflow: hidden;
        &.massifBox2{
          display:block;
          position: relative;
          z-index: 2000;
          .massifPage{
            position: absolute;
            z-index: 2000;
            left: 12px;
            top: 12px;
            height: auto;
            max-height: calc(100vh - 76px);
          }
          .mapbox{
            position: static;
          }
        }
        .massifPage{
            width: 380px;
            height: calc(100vh - 76px);
            box-sizing: border-box;
            background-color: #fff;
            box-shadow: rgba(0, 0, 0, 0.15) 0px 2px 4px 0px;
            padding: 0;
            margin-right:10px ;
            //overflow: hidden;
            //overflow-y: auto;
            
        }
        .mapbox{
            flex: 1;
            box-sizing: border-box;
            background: #b6b5b5;
            width: 100%;
            height: calc(100vh - 76px);
            overflow: hidden;
            position: relative;
            z-index: 1000;
        }
    }
  </style>
